<script>
    jQuery(function($) {
        document.getElementById('a').onclick = function () {
            alert(screen.width + "px");
        }
    });
</script>
<div class="bord">
    <div class="title">width</div>
    <div class="introduce">
        width 属性声明了显示浏览器的屏幕的宽度，以像素计。
    </div>
</div>
<div class="bord">
    <div class="title">演示效果</div>
    <button class="introduce" id="a">打印当前浏览器宽度</button>
</div>
<div class="bord">
    <div class="title">代码</div>
    <div class="introduce">
        <pre>
                &lt;script&gt;
            jQuery(function($) {
                document.getElementById('a').onclick = function () {
                    alert(screen.width + "px");
                }
            });
                &lt;/script&gt;
        </pre>
    </div>
</div>